#ifndef NEOSLIDERPRIVATE_H
#define NEOSLIDERPRIVATE_H

#include "stdafx.h"
#include <QPainter>

class NeoSlider;
class NeoSliderPrivate : public QObject
{
    Q_OBJECT
    NEO_PRIVATE_CREATE(NeoSlider)
    NEO_PRIVATE_PROPERTY_CREATE_H(QColor, IndicatorColor)
    NEO_PRIVATE_PROPERTY_CREATE_H(QColor, TrackColor)
    NEO_PRIVATE_PROPERTY_CREATE_H(QColor, BackgroundColor)
public:
    NeoSliderPrivate(QObject *parent = nullptr);
    ~NeoSliderPrivate();

    int positionToValue(int position) const;
    int valueToPosition(int value) const;
    int mousePositionForValue(QPointF pos) const;
    void updateWidgetGeometry(QSize size);

    void drawBackground(QPainter *painter);
    void drawTrack(QPainter *painter);
    void drawIndicator(QPainter *painter);

private:
    int pIndicatorRadius;
    QPointF pIndicatorStartPosition;
};

#endif